
@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800;900&display=swap');

:root {
    --blue: #2b6fe5;
    --blue-dark: #1747a6;
    --navy: #0f172a;
    --slate: #64748b;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Nunito', sans-serif;
    color: var(--navy);
    background:
        radial-gradient(
            circle at 10% 10%,
            rgba(43, 111, 229, .16),
            transparent 28%
        ),
        radial-gradient(
            circle at 90% 85%,
            rgba(23, 71, 166, .13),
            transparent 30%
        ),
        linear-gradient(
            135deg,
            #f8fbff 0%,
            #eef5ff 48%,
            #e3efff 100%
        );
}

/* Page Container */

.page-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: clamp(18px, 3vw, 36px);
}

/* Header */

.hero {
    width: 100%;
    max-width: 900px;
    margin: 0 auto clamp(24px, 4vh, 42px);
    text-align: center;
}

.hero-badge {
    width: 74px;
    height: 74px;
    margin: 0 auto 16px;
    border-radius: 24px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: white;
    font-size: 31px;

    background: linear-gradient(
        135deg,
        var(--navy),
        var(--blue)
    );

    box-shadow: 0 12px 28px rgba(43, 111, 229, .24);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 7px 13px;
    margin-top: 15px;

    border-radius: 999px;
    background: rgba(255, 255, 255, .88);
    border: 1px solid rgba(43, 111, 229, .18);

    color: var(--blue-dark);
    font-size: 13px;
    font-weight: 800;
}

.hero h1 {
    margin: 0;
    font-size: clamp(32px, 5vw, 56px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -.03em;

    background: linear-gradient(
        90deg,
        var(--navy),
        var(--blue-dark),
        var(--blue)
    );

    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero p {
    max-width: 720px;
    margin: 14px auto 0;

    color: var(--slate);
    font-size: clamp(14px, 1.8vw, 18px);
    line-height: 1.6;
}

/* Grid Materi */

.games-grid {
    width: 100%;
    max-width: 1180px;
    margin: 0 auto;

    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(14px, 2vw, 22px);
}

/* Card */

.game-card {
    --card-color: var(--blue);
    --card-soft: rgba(43, 111, 229, .12);

    position: relative;
    min-height: 240px;
    padding: 24px 20px;
    overflow: hidden;

    border-radius: 24px;
    color: inherit;
    background: rgba(255, 255, 255, .94);

    border: 1px solid rgba(43, 111, 229, .13);
    box-shadow: 0 14px 34px rgba(15, 23, 42, .08);

    transition:
        transform .25s ease,
        box-shadow .25s ease,
        border-color .25s ease;
}

.game-card::before {
    content: "";
    position: absolute;

    width: 150px;
    height: 150px;
    border-radius: 50%;

    top: -68px;
    right: -54px;

    background: var(--card-soft);
    transition: transform .3s ease;
}

.game-card::after {
    content: "";
    position: absolute;

    left: 0;
    bottom: 0;
    width: 100%;
    height: 5px;

    background: linear-gradient(
        90deg,
        var(--navy),
        var(--card-color)
    );
}

.game-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 20px 42px rgba(15, 23, 42, .14);
    border-color: rgba(43, 111, 229, .30);
}

.game-card:hover::before {
    transform: scale(1.12);
}

/* Icon */

.icon-box {
    position: relative;
    z-index: 1;

    width: 70px;
    height: 70px;
    margin-bottom: 22px;

    border-radius: 22px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: white;
    font-size: 30px;

    background: linear-gradient(
        135deg,
        var(--navy),
        var(--card-color)
    );

    box-shadow: 0 10px 22px rgba(15, 23, 42, .16);
}

/* Text Card */

.game-card h2 {
    position: relative;
    z-index: 1;

    margin: 0 0 9px;
    color: var(--navy);

    font-size: 21px;
    font-weight: 900;
}

.game-card p {
    position: relative;
    z-index: 1;

    margin: 0;
    color: var(--slate);

    font-size: 14px;
    line-height: 1.55;
}

/* Warna Card */

.decomposition {
    --card-color: #2b6fe5;
    --card-soft: rgba(43, 111, 229, .12);
}

.pattern {
    --card-color: #00a8cc;
    --card-soft: rgba(0, 168, 204, .11);
}

.abstraction {
    --card-color: #4f46e5;
    --card-soft: rgba(79, 70, 229, .10);
}

.algorithm {
    --card-color: #1747a6;
    --card-soft: rgba(23, 71, 166, .10);
}

/* Tombol Test dan Start */

.action-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;

    margin: 38px auto 10px;
    flex-wrap: wrap;
}

.btn {
    min-width: 165px;
    padding: 14px 30px;

    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 10px;

    border-radius: 14px;
    border: none;

    color: #ffffff;
    text-decoration: none;

    font-family: 'Nunito', sans-serif;
    font-size: 17px;
    font-weight: 900;

    cursor: pointer;

    transition:
        transform .25s ease,
        box-shadow .25s ease,
        background .25s ease;
}

.btn:hover {
    transform: translateY(-4px);
}

.btn-test {
    background: linear-gradient(135deg, #fb923c, #ea580c);
    box-shadow: 0 10px 22px rgba(234, 88, 12, .23);
}

.btn-test:hover {
    background: linear-gradient(135deg, #f97316, #c2410c);
    box-shadow: 0 14px 26px rgba(234, 88, 12, .3);
}

.btn-start {
    background: linear-gradient(135deg, #22c55e, #15803d);
    box-shadow: 0 10px 22px rgba(21, 128, 61, .23);
}

.btn-start:hover {
    background: linear-gradient(135deg, #16a34a, #166534);
    box-shadow: 0 14px 26px rgba(21, 128, 61, .3);
}

/* Footer */

footer {
    margin-top: auto;
    padding-top: 30px;

    text-align: center;
    color: var(--slate);

    font-size: 13px;
    font-weight: 700;
}

/* Tablet */

@media (max-width: 1000px) {
    .games-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-width: 780px;
    }

    .game-card {
        min-height: 230px;
    }
}

/* Mobile */

@media (max-width: 600px) {
    .page-shell {
        padding: 16px;
    }

    .hero {
        margin-bottom: 20px;
    }

    .hero-badge {
        width: 60px;
        height: 60px;
        border-radius: 19px;
        font-size: 25px;
        margin-bottom: 12px;
    }

    .hero p {
        font-size: 14px;
    }

    .games-grid {
        grid-template-columns: 1fr;
        gap: 13px;
    }

    .game-card {
        min-height: 0;
        padding: 18px;
        border-radius: 20px;
    }

    .icon-box {
        width: 58px;
        height: 58px;
        border-radius: 18px;
        margin-bottom: 14px;
        font-size: 25px;
    }

    .game-card h2 {
        font-size: 19px;
    }

    .action-buttons {
        gap: 12px;
        margin-top: 28px;
    }

    .btn {
        min-width: 130px;
        padding: 13px 22px;
        font-size: 15px;
    }
}
